
/*   
 * File:jquery.time.js.js  
 * Date:2016-3-8  
 * Time:14:20:16  
 * Encoding:UTF-8  
 * Author:Expression KongAo is undefined on line 9, column 26 in Templates/Licenses/license-default.txt.  
 * Expression copyright is undefined on line 10, column 19 in Templates/Licenses/license-default.txt. 2016-3-8  
 * Description:  
 */  
var myDate = new Date();
var hours =  myDate.getHours();
var minutes =  myDate.getMinutes();
var seconds = myDate.getSeconds();
var intDiff = 86400-(hours*60*60)-(minutes*60)-(seconds);//倒计时总秒数
function timer(intDiff){
	window.setInterval(function(){
	var hour=0,
		minute=0,
		second=0;//时间默认值		
	if(intDiff > 0){
		hour = Math.floor(intDiff / (60 * 60));
		minute = Math.floor(intDiff / 60) - (hour * 60);
		second = Math.floor(intDiff) - (hour * 60 * 60) - (minute * 60);
	}
        if ( hour<= 9) hour = '0' + hour;
	if (minute <= 9) minute = '0' + minute;
	if (second <= 9) second = '0' + second;
	$('#hour_show').html('<s id="h"></s>'+hour+'时');
	$('#minute_show').html('<s></s>'+minute+'分');
	$('#second_show').html('<s></s>'+second+'秒');
	intDiff--;
	}, 1000);
} 
$(function(){
	timer(intDiff);
});	

